<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="shiro" uri="http://shiro.apache.org/tags"%>


<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="robots" content="follow, index" />
<meta name="author" content="iune co." />
<meta name="description"
	content="IUNE有最好的库存管理SaaS软件。以更快更高的准确度，跟进实时数据的访问和库存移动。" />
<meta name="keywords"
	content="库存, 存货管理, 库存管理, 仓库管理, 云ERP, 云逸ERP, 中小型企业云ERP, SaaS ERP软件/系统" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title></title>

<style type="text/css">
td {
	padding: 0px;
	width: 100px;
}
</style>

</head>
<body>



	<div class="container-fluid" data-ng-controller="recSKHXCtrl as Model">
		
			
			<div class="row" style="margin-top:5px;">
				<div class="col-sm-12">
					<form class="form-horizontal" style="margin-bottom:5px;background-color:#dddddd;">
						<div class="row">
							<div class="col-sm-6">
								<div class="form-group form-group-sm" style="margin-bottom:0px;">
									<label class="col-sm-2 control-label">客户</label>
									<div class="col-sm-10">
										<div id="customerNo" class="input-group">
											<input type="text" class="form-control" data-ng-model="customerNo" ng-blur="Model.customerOnBlur(this)" required/> 
											<span class="input-group-btn">
												<button class="btn btn-default btn-sm" data-ng-click="Model.triggerCustomerNoClick()">
													<span class="glyphicon glyphicon-th-list" aria-hidden="true"></span>
												</button>
											</span>
											<input type="text" class="form-control" data-ng-model="customerName" readonly/>
											<span class="input-group-btn">
												<button class="btn btn-default btn-sm" data-ng-click="Model.refresh()" ng-disabled="customerID==null">
													<span class="glyphicon glyphicon-refresh" aria-hidden="true"></span> 筛选
												</button>
											</span>
										</div>
									</div>
								</div>
							</div>
						</div>
					</form>
				</div>
			</div>



		<div class="row">
			<div class="col-sm-12">
<div class="panel panel-success">
  <!-- Default panel contents -->
  <div class="panel-heading">到款：</div>

  <!-- Table -->
			<div class="table-responsive">
				<table class="table table-hover table-condensed" style="margin:0px;">
					<thead>

						<tr>
							<th></th>
							<th>#</th>
							<th><input type="checkbox" data-ng-model="checkboxValue1" data-ng-click="Model.checkbox1Click($event)"></th>
							<th>单据类型</th>
							<th>单号</th>
							<th>结算方式</th>
							<th>单据日期</th>
							<th>实收金额</th>
							<th>未核销金额</th>
							<th>核销金额</th>
							<th>备注</th>
							<th>核销状态</th>
							
							<th>订单号</th>
						</tr>
					</thead>
					<tbody>
						<tr data-ng-show="row.userdata.recordState!='delete'"
							data-ng-class="{true:'active'}[Model.dataMaster1.currentIndex==Model.dataMaster1.rows.indexOf(row)]"
							data-ng-click="Model.dataMaster1.onRowClick(row,$event)"
							data-ng-repeat="row in Model.dataMaster1.rows">
							<td style="width: 10px;"><span
								data-ng-show="Model.dataMaster1.currentIndex==Model.dataMaster1.rows.indexOf(row)"
								class="glyphicon glyphicon-hand-right" aria-hidden="true"></span></td>

							<td style="width: 10px;">{{Model.dataMaster1.rows.indexOf(row)+1}}<span></span></td>
							<td style="width: 10px;"><input type="checkbox" ng-change="Model.checkbox1ValueChanged()" data-ng-model="row.userdata.checked"></td>
							<td style="width: 100px;"><span
								data-ng-bind="row.billTypeName.value"></span></td>
							<td style="width: 100px;"><span
								data-ng-bind="row.accountPaymentNo.value"></span></td>
							<td style="width: 100px;"><span
								data-ng-bind="row.settleCategoryLabel.value"></span></td>
							<td style="width: 100px;"><span
								data-ng-bind="row.orderDate.value"></span></td>
							<td style="width: 100px;"><span
								data-ng-bind="row.orderAmount.value"></span></td>
							<td style="width: 100px;">
								<span data-ng-bind="row.pendingAmount.value"></span>
							</td>
							<td style="width: 100px;" td-input="number"
								data-ng-model="row.orderAmountCleared.value"><span
								data-ng-bind="row.orderAmountCleared.value"></span></td>
							<td style="width: 100px;"><span
								data-ng-bind="row.comments.value"></span></td>
							<td style="width: 60px;"><span
								data-ng-bind="row.handlingLabel.value"></span></td>
							
							<td style="width: 100px;"><span
								data-ng-bind="row.orderNo.value"></span></td>

						</tr>

					</tbody>
				</table>
			</div>
	<div class="panel-footer">
		<p>到款合计：{{clearAmountTotal}}</p>
	</div>
</div>
			</div>
		</div>



		<div class="row">
			<div class="col-sm-12">
<div class="panel panel-warning">
  <!-- Default panel contents -->
  <div class="panel-heading">应收款：</div>

  <!-- Table -->
			<div class="table-responsive">
				<table class="table table-hover table-condensed" style="margin:0px;">
					<thead>

						<tr>
							<th></th>
							<th>#</th>
							<th><input type="checkbox" data-ng-model="checkboxValue2" data-ng-click="Model.checkbox2Click($event)"></th>
							<th>单据类型</th>
							<th>单号</th>
							<th>发票号</th>
							<th>单据日期</th>
							<th>应收金额</th>
							<th>应收余额</th>
							<th>核销金额</th>
							<th>现金折扣</th>
							<th>备注</th>
							<th>核销状态</th>
							
							<th>订单号</th>
						</tr>
					</thead>
					<tbody>
						<tr data-ng-show="row.userdata.recordState!='delete'"
							data-ng-class="{true:'active'}[Model.dataMaster2.currentIndex==Model.dataMaster2.rows.indexOf(row)]"
							data-ng-click="Model.dataMaster2.onRowClick(row,$event)"
							data-ng-repeat="row in Model.dataMaster2.rows">
							<td style="width: 10px;"><span
								data-ng-show="Model.dataMaster2.currentIndex==Model.dataMaster2.rows.indexOf(row)"
								class="glyphicon glyphicon-hand-right" aria-hidden="true"></span></td>

							<td style="width: 10px;">{{Model.dataMaster2.rows.indexOf(row)+1}}<span></span></td>
							<td style="width: 10px;"><input type="checkbox" ng-change="Model.checkbox2ValueChanged()" data-ng-model="row.userdata.checked"></td>
							<td style="width: 100px;"><span
								data-ng-bind="row.billTypeName.value"></span></td>
							<td style="width: 100px;"><span
								data-ng-bind="row.accountInvoiceNo.value"></span></td>
							<td style="width: 100px;"><span
								data-ng-bind="row.invoiceCode.value"></span></td>
							<td style="width: 100px;"><span
								data-ng-bind="row.orderDate.value"></span></td>
							<td style="width: 100px;"><span
								data-ng-bind="row.orderAmountTotal.value"></span></td>
							<td style="width: 100px;">
								<span data-ng-bind="row.pendingAmount.value"></span>
							</td>
							<td style="width: 100px;" td-input="number"
								data-ng-model="row.orderAmountCleared.value"><span
								data-ng-bind="row.orderAmountCleared.value"></span></td>
							<td style="width: 100px;" td-input="number"
								data-ng-model="row.discountCash.value"><span
								data-ng-bind="row.discountCash.value"></span></td>
							<td style="width: 100px;"><span
								data-ng-bind="row.comments.value"></span></td>
							<td style="width: 60px;"><span
								data-ng-bind="row.handlingLabel.value"></span></td>
							
							<td style="width: 100px;"><span
								data-ng-bind="row.orderNo.value"></span></td>

						</tr>

					</tbody>
				</table>
			</div>
	<div class="panel-footer">
		<p>核销金额合计：{{orderAmountCleared}}&nbsp&nbsp&nbsp&nbsp&nbsp现金折扣金额合计：{{discountCash}}</p>
	</div>
</div>
			</div>
		</div>


			
			<div class="row" style="margin-top:5px;">
				<div class="col-sm-12">
					<form class="form-horizontal" id="hx" style="margin-bottom:5px;background-color:#dddddd;">
						<div class="row">
							<div class="col-sm-6">
								<div id="writeOffNo" class="form-group form-group-sm" style="margin-bottom:0px;">
									<label class="col-sm-2 control-label">核销批号</label>
									<div class="col-sm-10">
										<div class="input-group">
											<input type="text" class="form-control" holdplace="长度不能小于4"
												name="writeOffNo" 
												required="true" 
												ng-minlength=4 
						            			ng-maxlength=20
												data-ng-model="writeOffNo" ng-blur="Model.writeOffNoOnBlur(this)" required/> 
											<span class="input-group-btn">
												<button class="btn btn-primary btn-sm" data-ng-click="Model.hxClick($event)" ng-disabled="writeOffNo==null || writeOffNo==''">
													<span class="glyphicon glyphicon-ok" aria-hidden="true"></span> 核销
												</button>
												<button class="btn btn-default btn-sm" data-ng-click="Model.close($event)">
													<span class="glyphicon glyphicon-remove" aria-hidden="true"></span> 取消
												</button>
											</span>
										</div>
										<span class="glyphicon glyphicon-ok form-control-feedback" ng-show="hx.writeOffNo.$dirty && hx.writeOffNo.$valid"></span>
									</div>
								</div>
							</div>
						</div>
					</form>
				</div>
			</div>

	</div>


<br>


</body>

</html>

